// 给对象属性添加类型注解
let proson : {
    uname: string;
    age: number;
    sayHi: () => void;
    sing:(name: String) => void;
    sum: (num1:number, num2:number)=> number

}
proson = {
    uname: '夏天',
    age: 28,
    sayHi:()=>{
        console.log('hello world')
    },
    sing: (name) => {
        console.log(name)
    },
    sum:(n1, n2) => {
        return n1 + n2
    }

}

console.log(proson)